﻿namespace HKTools
{
    public interface IHK_ChildPanelBase
    {
        void Init();
        void Open();
        void Close();
        void Pause();
        void Resume();
    }

    public abstract class HK_ChildPanelBase : HKUIFramework_BaseController, IHK_ChildPanelBase
    {
        /// <summary>
        /// 初始化界面
        /// </summary>
        public abstract void OnInit();

        /// <summary>
        /// 显示界面
        /// </summary>
        public abstract void OnOpen();

        /// <summary>
        /// 退出界面
        /// </summary>
        public abstract void OnClose();

        /// <summary>
        /// 暂停界面
        /// </summary>
        public abstract void OnPause();

        /// <summary>
        /// 恢复界面
        /// </summary>
        public abstract void OnResume();

        public void Init()
        {
            OnInit();
        }

        public void Open()
        {
            OnOpen();
        }

        public void Close()
        {
            OnClose();
        }

        public void Pause()
        {
            OnPause();
        }

        public void Resume()
        {
            OnResume();
        }
    }
}
